package com.example.forum2.Service;

import com.example.forum2.model.Message;
import org.apache.ibatis.annotations.Param;
import org.springframework.transaction.annotation.Transactional;

import java.util.List;

public interface IMessageService {
    void create(Message message);
    Integer selectUnreadCount( Long receiveUserId);
    List<Message> selectByReceiveUserId(@Param("receiveUserId") Long receiveUserId);
    void updateStateById(Long id,Byte state);
    Message selectById(Long id);
    @Transactional
    void reply(Long repliedId,Message message);
}
